<template>
  <div class="container">
      <div class="wxkj-tab mt15 mb15">
            <el-tabs v-model="state" @tab-click='tabSwitch'>
                <el-tab-pane label="新简历" name="0">
                </el-tab-pane>
                <el-tab-pane label="初筛" name="3">
                </el-tab-pane>
                <el-tab-pane label="面试" name="4"></el-tab-pane>
                <el-tab-pane label="录用" name="5"></el-tab-pane>
            </el-tabs>
        </div>

        
        <personnel-view :components="true" :state="state" :jobId="jobId" :jobName="jobName" ref="personnel"/>
  </div>
</template>

<script>
import personnelView from '@/views/special-session/components/personnel'
export default {
  name: '',
  components: {personnelView},
  props: {},
  data() {
    return {
        state: '0',
        jobId: '',
        jobName: ''
    };
  },
// 方法
  methods: {
    tabSwitch(){
      this.$refs.personnel.pageInitList(this.state);
    }
  },
// 生命周期 - 创建完成（可以访问当前this实例）
  created() {
    let params = this.$route.params;
    if(params.id){
      this.state = params.state.toString();
      this.jobId = params.id;
      this.jobName = params.jobName;
    }
  },
// 生命周期 - 挂载完成（可以访问DOM元素）
  mounted() {},
// 销毁
  destroyed() {}
};
</script>
<style lang="scss" scoped>
</style>